<?php

include 'bootstrap.php';
$smarty->display('header.tpl');

try {
    if (file_exists($_modulo . '/' . $_controlador . '.php')) {
        include $_modulo . '/' . $_controlador . '.php';
    } else {
        $templatePadrao = '404.tpl';
    }
} catch (PDOException $e) {
    new Excecao($e);
} catch (Exception $e) {
    new Excecao($e);
}
$smarty->display($templatePadrao);
$smarty->display('footer.tpl');
